﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace Face.Web.VideoPage
{
    public partial class VideoHome : System.Web.UI.Page
    {
        private static IBLL.IVideo bll = BLLFactory.DataAccess.GetVideo();
        protected void Page_Load(object sender, EventArgs e)
        {
            bindData();
        }

        private void bindData()
        {
            //调用业务层
            Video_List.DataSource = bll.GetHotVideo();
            Video_List.DataBind();
            Repeater1.DataSource = bll.GetHotVideo();
            Repeater1.DataBind();
            Repeater2.DataSource = bll.GetHotVideo();
            Repeater2.DataBind();
            Repeater3.DataSource = bll.GetHotVideo();
            Repeater3.DataBind();
        }

        protected void rpt_Video_ItemCommand(object source, RepeaterCommandEventArgs e)
        {

        }

        protected void rpt_Repeater1_ItemCommand(object source, RepeaterCommandEventArgs e)
        {

        }

        protected void rpt_Repeater2_ItemCommand(object source, RepeaterCommandEventArgs e)
        {

        }

        protected void rpt_Repeater3_ItemCommand(object source, RepeaterCommandEventArgs e)
        {

        }

        protected void btn_logout(object sender, EventArgs e)
        {
            Session.Remove("user");
            Response.Redirect("/login_and_signup/login.aspx");
        }
    }
}